17#define MRB_EACH_OBJ_OK 0
18#define MRB_EACH_OBJ_BREAK 1
19typedef int (mrb_each_object_callback)(
mrb_state *mrb,
struct RBasic *obj,
void *data);
20void mrb_objspace_each_objects(
mrb_state *mrb, mrb_each_object_callback *callback,
void *data);
21size_t mrb_objspace_page_slot_size(
void);
24#ifndef MRB_GC_ARENA_SIZE
25#define MRB_GC_ARENA_SIZE 100
28#ifndef MRB_GRAY_STACK_SIZE
29#define MRB_GRAY_STACK_SIZE 1024
33 MRB_GC_STATE_ROOT = 0,
43 struct RBasic *gray_stack[MRB_GRAY_STACK_SIZE];
44 size_t gray_stack_top;
45 mrb_bool gray_overflow:1;
47 size_t live_after_mark;
49 size_t oldgen_threshold;
53 int current_white_part :2;
54 mrb_bool iterating :1;
56 mrb_bool generational :1;
58 mrb_bool out_of_memory :1;
60 size_t malloc_increase;
61 size_t malloc_threshold;
63#ifdef MRB_GC_FIXED_ARENA
64 struct RBasic *arena[MRB_GC_ARENA_SIZE];
72 uint32_t gc_total_count;
73 uint32_t minor_gc_count;
74 uint32_t major_gc_count;
mruby common platform definition"
#define MRB_END_DECL
End declarations in C mode.
Definition common.h:28
#define MRB_BEGIN_DECL
Start declarations in C mode.
Definition common.h:26
#define MRB_API
Declare a public mruby API function.
Definition common.h:108